package edu.chl.tda367.mynotes.ctrl;

import edu.chl.tda367.mynotes.core.MyNotes;

/*
 * A controller class that checks what kind of format change the user has
 * made. Sends the information to the model.
 */

public class FormatTextCtrl implements ICtrl {

	public void execute(String s){
		
		if(s.equals("bold")){
			MyNotes.getInstance().setBold();
		} else if(s.equals("italic")){
			MyNotes.getInstance().setItalic();
		} else if(s.equals("underline")){
			MyNotes.getInstance().setUnderline();
		} else if(s.equals("strikeThrough")){
			MyNotes.getInstance().setStrikeThrough();
		} else if(s.equals("superscript")){
			MyNotes.getInstance().setSuperscript();
		} else if(s.equals("subscript")){
			MyNotes.getInstance().setSubscript();
		} else if(s.equals("size")){
			MyNotes.getInstance().setSize();
		} else if(s.equals("font")){
			MyNotes.getInstance().setFont();
		}
		
	}

	@Override
	public void execute() {
		
	}
}
